package io.github.viscent.mtpattern.ch13.pipeline.example;

/**
 * 记录保存任务
 */
public class RecordSaveTask {

    /**
     * 记录列表
     */
    public final Record[] records;

    /**
     * 保存到的文件索引
     */
    public final int targetFileIndex;

    /**
     * 记录日期
     */
    public final String recordDay;

    public RecordSaveTask(Record[] records, int targetFileIndex) {
        this.records = records;
        this.targetFileIndex = targetFileIndex;
        this.recordDay = null;
    }

    public RecordSaveTask(String recordDay, int targetFileIndex) {
        this.records = null;
        this.targetFileIndex = targetFileIndex;
        this.recordDay = recordDay;
    }
}
